﻿
using System;
using System.ComponentModel;

namespace Sharp.Platform.Configuration
{
    /// <summary>
    /// 平台的系统配置
    /// </summary>
    [DisplayName("平台设置")]
    public class PortalConfig : ISystemConfig
    {
        /// <summary>
        /// 平台的系统级
        /// </summary>
        public PortalConfig()
        {
            IsPrintPreview = true;
            IsPrintShowDialog = true;
            LabelSeparator = "：";
            LabelAlign = "right";
            IsInputForLogin = true;
            EnableOrgPermission = true;
        }

        /// <summary>
        /// 预览报表
        /// </summary>
        [DisplayName("预览报表")]
        public bool IsPrintPreview { get; set; }
        /// <summary>
        /// 显示打印对话框
        /// </summary>
        [DisplayName("显示打印对话框")]
        public bool IsPrintShowDialog { get; set; }
        /// <summary>
        /// 是否全打
        /// </summary>
        [DisplayName("是否全打")]
        public bool IsPrintTextOnly { get; set; }

        /// <summary>
        /// Ext标签和输入框分隔符
        /// </summary>
        [DisplayName("Ext标签和输入框分隔符")]
        public string LabelSeparator { get; set; }
        /// <summary>
        /// Ext标签对齐
        /// </summary>
        [DisplayName("Ext标签对齐")]
        public string LabelAlign { get; set; }
        /// <summary>
        /// 输入用户名方式登录
        /// </summary>
        [DisplayName("输入用户名方式登录")]
        public bool IsInputForLogin { get; set; }
        /// <summary>
        /// 启用组织权限
        /// </summary>
        public bool EnableOrgPermission { get; set; }


        /// <summary>
        /// 配置文件的文件名
        /// </summary>
        /// <value>The name of the configuration file.</value>
        public string ConfigFileName
        {
            get { return "CEMS.Config"; }
        }
 
    }
}